From fd1018a503a5914e3b8371f6f37e4ce29dfc4ab0 Mon Sep 17 00:00:00 2001 From: Samuel Mimram Date: Wed, 6 Sep 2006 20:24:08 +0000 Subject: [PATCH] Conditional dependency on ocaml-base-nox for native/byte packages. --- debian/policy/chapter-progpack.xml | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/debian/policy/chapter-progpack.xml b/debian/policy/chapter-progpack.xml index f972e232..f380dce7 100644 --- a/debian/policy/chapter-progpack.xml +++ b/debian/policy/chapter-progpack.xml @@ -128,6 +128,25 @@ the requirements of the compilation of the program. binary-indep: build install dh_gencontrol -i -- -VF:OCamlABI="$(OCAMLABI)" - + + + + In the case where there is only one package, which provides either a native version where available or a bytecode version otherwise, the dependency on ocaml-base-nox-&ocaml-version; should be added only when the package is built in native mode. For example, the debian/control of approx contains: + + Package: approx + Architecture: any + Depends: ${shlibs:Depends}, ${F:OCamlRun}, adduser, bzip2, curl + + and the corresponding debian/rules contains: + + OCAMLABI = $(shell ocamlc -version) + BYTECODE = $(shell [ -x /usr/bin/ocamlopt ] || echo yes) + OCAMLRUN = $(if $(BYTECODE),ocaml-base-nox-$(OCAMLABI)) + ... + binary-arch: + ... + dh_gencontrol -- -VF:OCamlRun="$(OCAMLRUN)" + + -- 2.30.2